cmake_minimum_required(VERSION 3.29)
project(Compression)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_EXE_LINKER_FLAGS -static)

include_directories("${PROJECT_BINARY_DIR}")

file(GLOB_RECURSE mains RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" "${CMAKE_CURRENT_SOURCE_DIR}/*.cpp")
foreach(mainfile IN LISTS mains)
    get_filename_component(mainname ${mainfile} NAME_WE)
    add_executable(${mainname} ${mainfile}
            rlezip/zip_utils.h
            rlezip/zip_utils.cpp
            rleunzip/unzip_utils.h
            rleunzip/unzip_utils.cpp
            rleunzip/unzip_utils.cpp
            rleunzip/unzip_utils.cpp)
endforeach()